package lib.wman.org.mvp.demo;

import android.widget.TextView;

import lib.wman.org.mvp.R;
import lib.wman.org.mvp.view.AppDelegate;

public class SettingDelegate extends AppDelegate {
    @Override
    public int getRootLayoutId() {
        return R.layout.delegate_simple;
    }

    @Override
    public void initWidget() {
        super.initWidget();
        TextView textView = get(R.id.text);
        textView.setText("在视图代理层创建布局");
    }

    public void setText(String text) {
        //get(id)等同于bindview(id)
        TextView textView = get(R.id.text);
        textView.setText(text);
    }
}
